import request from "@/utils/request";
export function orderCreate(data) {
    return request({
         url:'/orders/create',
         header:{
            Authorization: uni.getStorageSync('userProfile').token
         },
         method:'POST',
         data:data
     })   
 }


 export function ordersPayInfo(order_number) {
    return request({
         url:'/my/orders/req_unifiedorder',
         header:{
            Authorization: uni.getStorageSync('userProfile').token
         },
         method:'POST',
         data:{
            order_number:order_number
         }
     })   
 }

// 检查并更新订单的支付状态
 export function checkOrder(order_number) {
    return request({
         url:'/my/orders/chkOrder',
         header:{
            Authorization: uni.getStorageSync('userProfile').token
         },
         method:'POST',
         data:{
            order_number:order_number
         }
     })   
 }